package com.atguigu.yygh.statist.controller;

import com.atguigu.yygh.common.result.Result;
import com.atguigu.yygh.order.OrderFeignClient;
import com.atguigu.yygh.vo.order.OrderCountQueryVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ybl
 * @version 1.9
 * @date 2021/5/31 20:09
 */
@Api(tags = "统计管理接口")
@RestController
@RequestMapping("/admin/statistics")
public class StatisticsController {

  @Autowired
  private OrderFeignClient orderFeignClient;

  @GetMapping("getCountMap")
  public Result getCountMap(@ApiParam(name = "orderCountQueryVo", value = "查询对象", required = false)
                                OrderCountQueryVo orderCountQueryVo) {
    return Result.ok(orderFeignClient.getCountMap(orderCountQueryVo));
  }


}
